import axios from "axios";
export let getlist = ()=>{
    return (dispatch)=>{
        axios.get("/api/list").then(res=>{
            console.log(res.data);
            dispatch({
                type:"getlist",
                payload:res.data
            })
        })
    }
}
export let addshop = (item)=>{
    return {
        type:"addshop",
        payload:item
    }
}
export let addFn = (id)=> {
    return {
        type :"addFn",
        payload:id
    }
}
export let RemoveFn = (id)=>{
    return {
        type:"RemoveFn",
        payload:id
    }
}
export let changeFn = (id)=>{
    return {
        type:"changeFn",
        payload:id
    }
}
export let checkallfn = ()=>{
    return {
        type:"checkallfn"
    }
}